package cn.lvji.springboot.learn3.controller;

import javax.servlet.*;
import java.io.IOException;

public class TestServletHandlerAdapter implements Servlet {

    @Override
    public void init(ServletConfig config) throws ServletException {
        System.out.println("init servlet");
    }

    @Override
    public ServletConfig getServletConfig() {
        return null;
    }

    @Override
    public void service(ServletRequest request, ServletResponse response) throws ServletException, IOException {
        String aa = request.getParameter("aa");
        response.getWriter().println("aa paramter is " + aa);
        response.getWriter().flush();
    }

    @Override
    public String getServletInfo() {
        return null;
    }

    @Override
    public void destroy() {

    }
}
